import request from '@/utils/request'

// 查询题目库列表
export function listExaminationquestion(query) {
  return request({
    url: '/system/examinationquestion/list',
    method: 'get',
    params: query
  })
}

// 查询题目库详细
export function getExaminationquestion(questionId) {
  return request({
    url: '/system/examinationquestion/' + questionId,
    method: 'get'
  })
}

// 新增题目库
export function addExaminationquestion(data) {
  return request({
    url: '/system/examinationquestion',
    method: 'post',
    data: data
  })
}

// 修改题目库
export function updateExaminationquestion(data) {
  return request({
    url: '/system/examinationquestion/update',
    method: 'post',
    data: data
  })
}

// 删除题目库
export function delExaminationquestion(questionId) {
  return request({
    url: '/system/examinationquestion/' + questionId,
    method: 'delete'
  })
}

// 导出题目库
export function exportExaminationquestion(query) {
  return request({
    url: '/system/examinationquestion/export',
    method: 'get',
    params: query
  })
}

//确认选择题目到该试卷
export function confirmSelection(data) {
  return request({
    url: '/system/back/safetyexaminationback/insertPaperQuestion',
    method: 'post',
    data: data
  })
}